<?php


namespace App\Enums;


class ErmEnum
{

    const PUBLIC_TYPE = 1;//大众名单
    const WHITE_TYPE = 2;//白名单
    const GRAY_TYPE = 3;//灰名单
    const BLACK_TYPE = 4;//黑名单

    //用户类型
    const USER_TYPE = [
        1 => '普通用户',
        2 => '官方管理',
        3 => '公会会长',
        4 => '公会厅主',
        5 => '公会成员'
    ];

    //变动类型
    const CHANGE_TYPE_RECHARGE = ['type' => 1];//充值
    const CHANGE_TYPE_WITHDRAW = ['type' => 2, 'child_type' => [2, 23, 24]];//提现
    const CHANGE_TYPE_CONSUMPTION = ['type' => 3, 'child_type' => [19, 4, 141, 142, 100, 52, 133, 222]];//消费
    const CHANGE_TYPE_EXCHANGE = ['type' => 4, 'child_type' => [8]];//兑换

    const WHITE_PAY_ID_NUM = 5;//自动加白：使用白名单内用户微信微信open_id 支付宝buyer_id，连续N次以上相同
    //收益类型
    const EARNINGS_TYPE = [6, 53, 143, 144, 160, 223, 224];//收益类型
    const EARNINGS_TYPE_MONEY_TB    = [53, 143, 144, 223, 224];//收益类型（ln_account_money_log表中存储的类型）
    const EARNINGS_TYPE_EARNINGS_TB = [6, 160];//收益类型（ln_account_earnings_log表中存储的类型）

    //参数配置
    const USER_WX_PAY_OPEN_ID_LIMIT = 'USER_WX_PAY_OPEN_ID_LIMIT';
    const USER_ALI_PAY_BUYER_ID_LIMIT = 'USER_ALI_PAY_BUYER_ID_LIMIT';
    const AUTO_REMOVE_GRAY_LIST = 'AUTO_REMOVE_GRAY_LIST';
    const TEST_USER_LIST = 'TEST_USER_LIST';

    const USER_WX_PAY_OPEN_ID_LIMIT_BLACK = 'USER_WX_PAY_OPEN_ID_LIMIT_BLACK';
    const USER_ALI_PAY_BUYER_ID_LIMIT_BLACK = 'USER_ALI_PAY_BUYER_ID_LIMIT_BLACK';
    const WITHIN_SAME_ORDER = 'WITHIN_SAME_ORDER';
    const DEVICE_NUM = 'DEVICE_NUM';
    const AUTO_GRAY_RECHARGE = 'AUTO_GRAY_RECHARGE';
    const ERM_SWITCH = 'ERM_SWITCH';
    const AUTO_GRAY_DEVICE_RISK = 'AUTO_GRAY_DEVICE_RISK';
    const AUTO_GRAY_BACKPACK = 'AUTO_GRAY_BACKPACK';
    const AUTO_ADD_BLACK_LIST = 'AUTO_ADD_BLACK_LIST';
    const WHITE_LIMIT_NUM = 'WHITE_LIMIT_NUM';
    const ALI_PAY_LINK_EXPIRE_TIME = 'ALI_PAY_LINK_EXPIRE_TIME';
    const WAIT_PAY_ORDER_LIMIT = 'WAIT_PAY_ORDER_LIMIT';
    const RECHARGE_NEED_CHECK = 'RECHARGE_NEED_CHECK';
    const RECHARGE_COUNT_NEED_CHECK = 'RECHARGE_COUNT_NEED_CHECK';
    const PUSH_NOTICE = 'PUSH_NOTICE';
    const HINT_CONTENT = 'HINT_CONTENT';

    const TYPE_MAP = [
        self::PUBLIC_TYPE => '大众名单',
        self::WHITE_TYPE => '白名单',
        self::GRAY_TYPE => '灰名单',
        self::BLACK_TYPE => '黑名单',
    ];

    const DEVICE_WHITE_LIST_KEY = 'erm:device:white';



}